package com.atguigu.gulimall.product.service;

import com.atguigu.gulimall.product.vo.Catalog2Vo;
import com.baomidou.mybatisplus.extension.service.IService;
import com.atguigu.common.utils.PageUtils;
import com.atguigu.gulimall.product.entity.CategoryEntity;
import com.fasterxml.jackson.core.JsonProcessingException;

import java.io.IOException;
import java.util.List;
import java.util.Map;

/**
 * 商品三级分类
 *
 * @author zhough
 * @email zhough@gmail.com
 * @date 2024-01-22 17:20:02
 */
public interface CategoryService extends IService<CategoryEntity> {

    PageUtils queryPage(Map<String, Object> params);

    List<CategoryEntity> listWithTree();

    List<Long> getCatelogPath(Long catelogId);

    void updateCascade(CategoryEntity category);

    List<CategoryEntity> selectLevel1Categories();

    Map<String, List<Catalog2Vo>> getCatalogJson() throws IOException, InterruptedException;
}

